﻿{extend name="layouts/base"}
{block name="header"}
<link rel="stylesheet" href="__STATIC__/wap/css/bootstrap.min_1.css">
<link rel="stylesheet" href="__STATIC__/wap/css/base_2.css">
<script src="__STATIC__/wap/js/jquery_2.js"></script>
<script src="__STATIC__/wap/js/autohidenav_1.js"></script>
<script src="__STATIC__/wap/js/common_2.js"></script>
<link rel="stylesheet" href="__STATIC__/wap/css/service.css">
{/block}
{block name="main"}
<div class="head-tit-top">
    <h2>全部服务</h2>
</div>
<div style="height:50px;"></div>
<div class="service">
    <div class="left">
        <ul>
            <?php
                foreach ($M['menu'] as $k => $v) {
             ?>
            <li class="<?php
                if ($k == 0){
                    echo 'cur';
                }
            ?>">
                    <div class="img">
                        <img src="{$v['service']}" alt="{$v['name']}">
                        <img class="hover-img" src="{$v['service']}" alt="{$v['name']}">
                    </div>
                    <p>{$v['name']}</p>
            </li>
            <?php
                }
            ?>
        </ul>
    </div>
    <div class="right">
        <?php
                foreach($M['menu'] as $k => $v){
        ?>
            <div class="menu-item" style="display: <?php
                    if ($k == 0) {
                        echo 'block';
                    } else {
                            echo '';
                    }
            ?>;margin-top:-70px;">
            <ul>
                <?php
                         foreach($v['children'] as $kk =>$vv) {
                ?>
                <li>
                    <h6>{$vv['name']}</h6>
                    <?php
                    if (isset($vv['children'])) {
                          foreach ($vv['children'] as $kkk=>$vvv) {
                    ?>
                    <div>

                        <a href="{$vvv['link']}" title="{$vvv['name']}">{$vvv['name']}</a>

                    </div>
                    <?php
                    }
                    }
                    ?>
                </li>
                <?php
                    }
                ?>
            </ul>
        </div>
        <?php
            }
        ?>
    </div>
</div>
<style>
    .navOnIcon{
        display:none;
    }
    #footer .cur .img .navIcon {
        display:none;
    }
    footer .cur .img .navOnIcon{
        display:block;
    }
</style>
{/block}

{block name="privateJs"}
<script>
    $(function () {
        $('.left li').click(function () {
            var index = $(this).index();
            $(this).addClass("cur").siblings().removeClass("cur");
            $(".menu-item").eq(index).show().siblings().hide();
            $("html,body").scrollTop(0);
        })
        $('.copy').hide();
    });
</script>
<script>
    window.mark = 'serviceClassify';
    $('[data-mark=' + window.mark + ']').addClass('cur');
</script>
{/block}